<template>
	<view class="main">
		<view class="center-box">
			<image src="https://wechat-pictures-1301970825.file.myqcloud.com/shop/icon_share.png"></image>
			<view class="title">{{msg}}</view>
			<view class="back-button" @click="go_index()">
				<button class="back-button-text" type="default" open-type="share">继续分享</button>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				list:[],
				type:1, // 1 未注册 2 其他
				msg:'点击按钮选择要分享的群或个人',
				pickupNo: '' ,// 提货编码
				name:''
			}
		},
		onLoad(req) {
			this.pickupNo = req.pickupNo
			this.getShop()
		},
		onShareAppMessage(res) {
		    return {
		      title:this.name+'为您发起提货，请确认提货信息',
		      path: '/pages/pickup/all?pickupNo='+this.pickupNo,
			  imageUrl:'https://wechat-pictures-1301970825.file.myqcloud.com/shop/img_tihuofenxiang.png'
		    }
		},
		methods: {
			// 获取详情
			getShop(){
				let postData = {}
				postData.pickupNo = this.pickupNo
				this.$javaApiErp.doRequest("post",'/rkkt/pickuplog/getShoperNameByPickupNo?pickupNo='+this.pickupNo,postData,'json').then(res=>{
					if(res.data.code === 0){
						this.name=res.data.data
					}
				})
			},
		}
	}
</script>

<style scoped>
.main{
	width: 100%;
	height: 100vh;
	background-color: #F3F5F8;
}
.center-box{
	height: 100vh;
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: center;
}
.center-box image {
	width: 400upx;
	height: 400upx;
}
.title {
	width: 550rpx;
	text-align: center;
	font-size: 36rpx;
	font-weight: bold;
	color: #333333;
	margin-top: 30rpx;
}
.back-button {
	display: flex;
	justify-content: center;
	align-items: center;
	width: 100%;
	margin-top: 80rpx;
}
.back-button-text{
	width: 500rpx;
	height: 98rpx;
	background: #5CAE77;
	border-radius: 49rpx;
	line-height: 98rpx;
	margin:0 auto;
	color: #fff;
	text-align: center;
	font-size: 39rpx;
	font-weight: 500;
	color: #FFFFFF;
}
</style>
